<?php
	
	class EbWidget extends EbDataHolder
	{
		protected $echo;
		
		public function init($echo,$data)
		{
			$this->echo = $echo;
			
			parent::mergeData($data,true);
		}
		
		protected function evalItemRenderer($item,$renderer)
		{
			if (is_array($item))
			{
				extract($item,EXTR_OVERWRITE);
			}
			else if (is_object($item))
			{
				extract(get_object_vars($item),EXTR_OVERWRITE);
			}
			
			$renderer = str_replace('\"','"',$renderer);
			$renderer = str_replace('"','\"',$renderer);

			eval("\$buffer = \"$renderer\";");
			
			return $buffer;
		}
	}